<?php
namespace app\admin\controller;

use app\common\controller\AdminBase;
use app\admin\model\Admin as Adm;
use app\admin\model\Category as Cate;
use app\admin\model\Role;

use think\Request;
use think\Loader;
use think\Url;

class Admin extends AdminBase
{
	public function _empty()
	{
		return $this->index();
	}
	public function index()
	{
		return 'INDEX';
	}

	public function log()
	{
		//查询管理日志
		$admin = Adm::get(1);

		return json($admin->log);
	}
	//权限认证需要更严谨的步骤,先放置一旁?
	public function role()
	{
		//权限管理测试
		$admin = Adm::get(1);

		$rule = Loader::model('Role')->rule();

		return json($rule);
	}
}